home *** CD-ROM | disk | FTP | other *** search
Text File | 1998-01-19 | 1.5 KB | 40 lines | [TEXT/ToyS] |
- -- Expand.rsrc
- set dlog128 to {bounds:[50, 50, 360, 162], style:standard window, closeable:true, name:"Copying", contents:[¬
- {class:icon push button, bounds:[10, 80, 30, 100], style:5, contents:1000}, ¬
- {class:gauge, bounds:[50, 30, 250, 42], max value:200}, ¬
- {class:static text, bounds:[120, 120, 300, 136], contents:"folder name"}, ¬
- {class:static text, bounds:[120, 140, 300, 156], contents:"file name"}, ¬
- {class:static text, bounds:[120, 160, 300, 176], contents:"count"}, ¬
- {class:static text, bounds:[120, 180, 300, 196], contents:"time"}, ¬
- {class:static text, bounds:[10, 120, 120, 136], contents:"Folder"}, ¬
- {class:static text, bounds:[10, 140, 120, 156], contents:"File"}, ¬
- {class:static text, bounds:[10, 160, 120, 176], contents:"Items Copied"}, ¬
- {class:static text, bounds:[10, 180, 120, 196], contents:"Time Remaining"}, ¬
- {class:group box, bounds:[40, 90, 300, 92]} ¬
- ] ¬
- }
-
- set isExpanded to false
- dd install with grayscale
- set d1 to dd make dialog dlog128
- repeat with n from 0 to 200
- dd set value of item 2 of d1 to n
- dd set contents of items 3 thru 6 of d1 to [n, n, n, n]
- set ui to dd interact with user for max ticks 6
- if ui = 1 then
- dd set contents of item 1 of d1 to 1001
- set R to dd get bounds of d1
- if isExpanded then -- Hide
- set item 4 of R to (item 4 of R) - 98
- set icn to 1000
- else -- Show
- set item 4 of R to (item 4 of R) + 98
- set icn to 1002
- end if
- dd set bounds of d1 to R
- set isExpanded to not isExpanded
- dd set contents of item 1 of d1 to icn
- end if
- if ui = -1 then exit repeat
- end repeat
- dd uninstall